﻿CREATE TABLE [dbo].[Room] (
    [RoomId]      INT             IDENTITY (1, 1) NOT NULL,
    [HotelId]     INT             NOT NULL,
    [Name]        NVARCHAR (128)  NULL,
    [Price]       NUMERIC (18, 2) NULL,
    [Description] NVARCHAR (512)  NULL,
    [RoomTypeId]  INT             NOT NULL,
    [BedCount]    INT             NOT NULL,
    CONSTRAINT [PK_Rooms] PRIMARY KEY CLUSTERED ([RoomId] ASC),
    CONSTRAINT [FK_Rooms_Hotel] FOREIGN KEY ([HotelId]) REFERENCES [dbo].[Hotel] ([HotelId]),
    CONSTRAINT [FK_Rooms_RoomType] FOREIGN KEY ([RoomTypeId]) REFERENCES [dbo].[RoomType] ([RoomTypeId])
);

